@import "nib"
@import "_variables"
@import "_util/mixin"
@import "_util/grid"

global-reset()

input, button
    margin: 0
    padding: 0
    &::-moz-focus-inner
        border: 0
        padding: 0

html, body, #container
    height: 100%

body
    color: color-default
    background: color-background
    font: font-size font-sans
    -webkit-text-size-adjust: 100%

a
    color: color-link
    text-decoration: none
    &:visited
        color: color-link

code
    margin: 0 2px
    color: #e96900
    padding: 3px 5px
    font-size: 0.9em
    border-radius: 2px
    font-family: font-mono
    background-color: #f8f8f8

.outer
    clearfix()
    max-width: (column-width + gutter-width) * columns + gutter-width
    margin: 0 auto
    padding: 0 gutter-width
    @media mq-mini
        padding: 0

.left, .alignleft
    float: left

.right, .alignright
    float: right

.clear
    clear: both

.logo
    width: logo-width
    height: logo-height
    background-repeat: no-repeat
    background-image: url(logo-url)
    background-size: logo-width logo-height

#container
    position: relative
    & > .outer
        margin-bottom: 30px

#main
    @media mq-normal
        column(main-column)
    @media mq-tablet
        if sidebar
            column(main-column-tablet)
        else
            width: 100%
    @media mq-mobile
        width: 100%
    @media mq-mini
        width: 100%

@import "_extend"
@import "_partial/header"
@import "_partial/profile"
@import "_partial/article"
@import "_partial/comment"
@import "_partial/archive"
@import "_partial/timeline"
@import "_partial/footer"
@import "_partial/sidebar"
@import "_partial/insight"
@import "_partial/donate"
@import "_highlight/index"

if sidebar is left
    #main
        float: right
    #profile
        float: right

#profile .inner,.article-inner {
  border-radius: 8px;
}
#sidebar {
  background: rgb(255,255,255);
  margin-top: block-margin !important;
  border-radius: 8px;
}
		
// 自己扩展的		
.article-entry blockquote p {
    margin: 0.5em 0;
}
.article-meta {
  line-height: 1.6em;
  padding: 5px 0;
  border-top: solid 1px #ecebeb;
  border-bottom: solid 1px #ecebeb;
}
.article-meta:before,.article-meta:after {
  content: "";
  display: table;
}
.article-meta:after {
  clear: both;
}
.article-meta > div {
  float: left;
  margin-right: 10px;
  padding-right: 10px;
  border-right: solid 1px #ecebeb;
}

// 首页自适应
@media screen and (min-width: 1200px) {
  #main {
    display: inline;
    float: left;
    width: 58.666666666666664%;
    margin: 0 0.666666666666667%;
  }
}
@media screen and (min-width: 800px) and (max-width: 1199px) {
  #main {
    display: inline;
    float: left;
    width: 72%;
    margin: 0 0.666666666666667%;
  }
}
@media screen and (min-width: 560px) and (max-width: 799px) {
  #main {
    width: 100%;
  }
}
@media screen and (max-width: 559px) {
  #main {
    width: 100%;
  }
}
@media screen and (min-width: 1200px) {
  #sidebar {
    width: 18.666666666666668%;
    margin: 0 0.666666666666667%;
  }
}
@media screen and (min-width: 800px) and (max-width: 1199px) {
  #sidebar {
    width: 25.333333333333336%;
    margin: 0 0.666666666666667%;
  }
}

.widget ul,
.widget ol {
  list-style: none;
  margin: 0;
}
.widget ul ul,
.widget ol ul,
.widget ul ol,
.widget ol ol {
  margin: 0 20px;
}
.widget ul ul,
.widget ol ul {
  list-style: disc;
}
.widget ul ol,
.widget ol ol {
  list-style: decimal;
}
.category-list-count,
.tag-list-count,
.archive-list-count {
  padding-left: 5px;
  color: #999;
  font-size: 0.85em;
}
.category-list-count:before,
.tag-list-count:before,
.archive-list-count:before {
  content: "(";
}
.category-list-count:after,
.tag-list-count:after,
.archive-list-count:after {
  content: ")";
}
.tagcloud a {
  margin-right: 5px;
}
@media screen and (min-width: 560px) and (max-width: 799px) {
  .widget-wrap {
    display: none;
  }
}
@media screen and (max-width: 559px) {
  .widget-wrap {
    display: none;
  }
}
.widget-title {
  color: #e84d1c;
}
.widget-title .fa {
  margin-right: 5px;
}
.widget a:hover {
  color: #e84d1c;
}
.widget ul ul,
.widget ol ul,
.widget dl ul,
.widget ul ol,
.widget ol ol,
.widget dl ol,
.widget ul dl,
.widget ol dl,
.widget dl dl {
  margin-left: 15px;
  list-style: disc;
}
.widget ul,
.widget ol {
  list-style: none;
}
.widget ul li,
.widget ol li,
.widget ul .category-list-child,
.widget ol .category-list-child {
  padding: 6px 0;
  font-size: 14px;
  border-bottom: 1px solid #e6e6e6;
}
.widget ul li a,
.widget ol li a,
.widget ul .category-list-child a,
.widget ul ul,
.widget ol ul,
.widget ul ol,
.widget ol ol {
  list-style: none;
}
.widget ul ul li,
.widget ol ul li,
.widget ul ol li,
.widget ol ol li {
  border: none;
}
.widget ul ul li:last-child,
.widget ol ul li:last-child,
.widget ul ol li:last-child,
.widget ol ol li:last-child {
  padding-bottom: 0px;
}
.widget ul:not(#recent-post) li a:before,
.widget ol:not(#recent-post) li a:before {
  color: #ccc;
  content: "\f054";
  font-size: 12px;
  margin-right: 6px;
  font-family: FontAwesome;
  -webkit-transition: 0.2s ease;
  -moz-transition: 0.2s ease;
  -ms-transition: 0.2s ease;
  transition: 0.2s ease;
}
.widget ul:not(#recent-post) li a:hover:before,
.widget ol:not(#recent-post) li a:hover:before {
  color: #e84d1c;
}
#toTop {
  display: none;
  cursor: pointer;
  text-align: center;
  width: 45px;
  height: 45px;
  color: #fff;
  font-size: 40px;
  line-height: 40px;
  background: #565a5f;
  opacity: 0.8;
  border-radius: 40px;
  bottom: 20px;
  position: fixed;
  z-index: 999;
}
@media screen and (min-width: 560px) and (max-width: 799px) {
  #toTop {
    width: 52px;
    height: 52px;
    font-size: 40px;
    line-height: 40px;
  }
}
@media screen and (max-width: 559px) {
  #toTop {
    width: 45px;
    height: 45px;
    font-size: 40px;
    line-height: 40px;
  }
}
#recent-post li:before,
#recent-post li:after {
  content: "";
  display: table;
}
#recent-post li:after {
  clear: both;
}
#recent-post.no-thumbnail li {
  padding: 10px 0px;
}
#recent-post li .item-thumbnail {
  opacity: 1;
  float: left;
  margin-left: -94px;
  -webkit-transition: all 0.2s ease;
  -moz-transition: all 0.2s ease;
  -ms-transition: all 0.2s ease;
  transition: all 0.2s ease;
}
#recent-post li .item-thumbnail .thumbnail {
  width: 80px;
  height: 80px;
  display: block;
  position: relative;
  overflow: hidden;
}
#recent-post li .item-thumbnail .thumbnail span {
  width: 100%;
  height: 100%;
  display: block;
}
#recent-post li .item-thumbnail .thumbnail .thumbnail-image {
  position: absolute;
  -webkit-background-size: cover;
  -moz-background-size: cover;
  background-size: cover;
  background-position: center;
}
#recent-post li .item-thumbnail .thumbnail .thumbnail-none {
  background-image: url("images/thumb-default-small.png");
  -webkit-background-size: 100% 100%;
  -moz-background-size: 100% 100%;
  background-size: 100% 100%;
}
#recent-post li .item-inner a a,
#recent-post li .item-inner .item-category a {
  color: #e84d1c;
}
#recent-post li .item-inner a a:hover,
#recent-post li .item-inner .item-category a:hover {
  color: #333;
}
#recent-post li .item-inner a a,
#recent-post li .item-inner .item-category a,
#recent-post li .item-inner a .fa,
#recent-post li .item-inner .item-category .fa {
  margin-right: 5px;
}
#recent-post li .item-inner .item-date {
  color: #aaa;
  font-size: 13px;
  text-transform: uppercase;
}
#recent-post li:hover .item-thumbnail {
  opacity: 0.8;
}
.ins-search {
  display: none;
}
.ins-search.show {
  display: block;
}
.ins-selectable {
  cursor: pointer;
}
.ins-search-mask,
.ins-search-container {
  position: fixed;
}
.ins-search-mask {
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 100;
  background: rgba(0,0,0,0.5);
}
.ins-input-wrapper {
  position: relative;
}
.ins-search-input {
  width: 100%;
  border: none;
  outline: none;
  font-size: 16px;
  -webkit-box-shadow: none;
  box-shadow: none;
  font-weight: 200;
  border-radius: 0;
  background: #fff;
  line-height: 20px;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  padding: 12px 28px 12px 20px;
  border-bottom: 1px solid #e2e2e2;
  font-family: "Microsoft Yahei Light", "Microsoft Yahei", Helvetica, Arial, sans-serif;
}
.ins-close {
  top: 50%;
  right: 6px;
  width: 20px;
  height: 20px;
  font-size: 16px;
  margin-top: -11px;
  position: absolute;
  text-align: center;
  display: inline-block;
}
.ins-close:hover {
  color: #006bde;
}
.ins-search-container {
  left: 50%;
  top: 100px;
  z-index: 101;
  bottom: 100px;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  width: 540px;
  margin-left: -270px;
}
@media screen and (max-width: 559px), screen and (max-height: 479px) {
  .ins-search-container {
    top: 0;
    left: 0;
    margin: 0;
    width: 100%;
    height: 100%;
    background: #f7f7f7;
  }
}

.copy-button {
    position: absolute;
    top: 5px;
    right: 5px;
    background: inherit;
    border: 0;
    font-size: 18px;
}
.article-entry .highlight {
    position: relative;
}
.invisible {
  display: none;
}
.fa {
	color: #e84d1c;
    display: inline-block;
    font: normal normal normal 14px/1 FontAwesome;
    font-size: inherit;
    text-rendering: auto;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}


#toc {
    line-height: 1em;
    font-size: 0.8em;
}
.toc-article {
    float: none;
    background: #f9f9f9;
    margin: 1em -20px 1em -20px;
    padding: 2em;
    border-radius: 0px;
}


.post-copyright {
    margin: 2em 0 0;
    padding: 0.5em 1em;
    border-left: 3px solid #ff1700;
    background-color: #f9f9f9;
    list-style: none;
}

.post-copyright li {
    display: list-item;
    text-align: -webkit-match-parent;
	margin: 5px 0 5px 0px;
}

// 原创CSS
.article-meta {
	line-height: 2.1em;		
}
span.article-type {
    margin-right: 8px;
    margin-top: 0;
    vertical-align: 2px;
	display: inline-block;
    width: 26px;
    height: 26px;
    line-height: 26px;
    text-align: center;
    font-size: 12px;
    border-radius: 50%;
}
span.article-type.type-1 {
    color: #38b7ea;
    border: 2px solid #38b7ea;
}
span.article-type.type-2 {
    color: #ca0c16;
    border: 2px solid #f4ced0;
}
span.article-type.type-3 {
    color: #00de3ca8;
    border: 2px solid #00de3ca8;
}

// tags 页面

.list-tags {
    text-align: center;
}
.list-tags a {
    margin: 2px 0px;
    display: inline-block;
    border-radius: 3px;
    padding: 5px 10px;
    //line-height: 24px;
    //font-size: 14px;
    text-decoration: none;
    color: #555;
    border: 1px solid #38b7ea;
}
a:visited {
    color: #e84d1c;
}


.timeline-wrap {
    margin: 10px 0px 20px 25px;
    border-left: 3px solid #eceff2;
}

.timeline-row {
    margin: 5px 0;
}

.timeline-row-major .node {
    width: 14px;
    height: 14px;
    font-size: 14px;
    margin: 0 0 0 -17px;
    padding: 6px 8px 10px;
}

.timeline-row-major .title {
    font-size: 18px;
    margin-left: 15px;
    line-height: 30px;
}







